package com.ssy.lingxi.marketing.model.bo;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.Valid;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Positive;
import java.math.BigDecimal;
import java.util.List;

/**
 * 抽奖 - BO
 * @author fhj
 * @date 2021/06/17
 * @version 2.0.0
 */
@EqualsAndHashCode(callSuper = true)
@Data
@ApiModel(value = "10",description = "抽奖")
public class LotteryBO extends ActivityDefinedBO{

    private static final long serialVersionUID = -4523366614445930536L;
    /**
     * 抽奖类型：1-订单抽奖 2-积分抽奖 3-行为抽奖 4-活动抽奖
     */
    @ApiModelProperty(dataType ="integer",value = "抽奖类型：1-订单抽奖 2-积分抽奖 3-行为抽奖 4-活动抽奖")
    private Integer lotteryType;

    /**
     * 订单抽奖 - 订单金额
     * */
    @ApiModelProperty(dataType ="float",value = "订单抽奖 - 订单金额")
    private BigDecimal orderPrice;

    /**
     * 积分抽奖 - 积分
     * */
    @ApiModelProperty(dataType ="integer",value = "积分抽奖 - 积分")
    private Integer integral;

    /**
     * 行为抽奖 - 1-申请会员 2-签到
     * */
    @ApiModelProperty(dataType ="integer",value = "行为抽奖 - 1-申请会员 2-签到")
    private Integer behavior;

    /**
     * 抽奖次数类型：1-每日 2-每周 3-每月 4-活动期内
     */
    @NotNull(message = "抽奖次数类型不能为空")
    @ApiModelProperty(dataType ="integer",value = "抽奖次数类型：1-每日 2-每周 3-每月 4-活动期内")
    private Integer lotteryNumType;

    /**
     * 抽奖次数
     */
    @Positive(message = "抽奖次数要大于0")
    @ApiModelProperty(dataType ="integer",value = "抽奖次数")
    private Integer lotteryNum;

    /**
     * 活动描述
     * */
    @ApiModelProperty(dataType ="string",value = "活动描述")
    private String describe;

    /**
     * 奖品
     * */
    @Valid
    @NotEmpty(message = "奖品不能为空")
    @ApiModelProperty(dataType ="array:object",value = "奖品")
    private List<PrizeBO> prizeList;
}